package com.gakj.truck.third.api.service;

import com.gakj.truck.third.api.mapper.TruckBrandMapper;
import com.gakj.truck.third.core.domain.TruckBrand;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by gc on 2016/5/25.
 */
@Service
public class TruckBrandService {

    @Autowired
    TruckBrandMapper brandMapper;

    public List<TruckBrand> getByName(String name){
        return brandMapper.getByName(name);
    }

    public TruckBrand getById(Integer id){
        return brandMapper.getById(id);
    }

    public List<TruckBrand> getAll(){
        return brandMapper.getAll();
    }

    public void save(TruckBrand truckBrand){
        brandMapper.save(truckBrand);
    }

    public void delete(Integer id){
        brandMapper.delete(id);
    }




}
